package cn.com.huzo.model.entities.master;

import huzofw.model.entities.BaseEntity;
import huzofw.model.entities.IAggregateRoot;
import java.io.Serializable;
import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.ToStringBuilder;

/**
 * 颜色实体类
 * <p>
 * @author 吴旭
 */
public class ColourEntity extends BaseEntity implements Serializable, IAggregateRoot {

    private static final long serialVersionUID = -6889638888474142302L;
    private Long ColourId;
    private String ColourCode;              // 编码，也是排序基础
    private Long CatalogueId;
    private String CatalogueName;
    private String ColourNumber;            // 色号
    private String ColourCnName;            // 颜色中文名
    private String ColourEnName;            // 颜色英文名
    private String ColourJpName;            // 颜色日文名
    private String Description;

    public Long getColourId() {
        return ColourId;
    }

    public Long getCatalogueId() {
        return CatalogueId;
    }

    public String getCatalogueName() {
        return CatalogueName;
    }

    public String getColourCode() {
        return ColourCode;
    }

    public String getColourNumber() {
        return ColourNumber;
    }

    public String getColourCnName() {
        return ColourCnName;
    }

    public String getColourEnName() {
        return ColourEnName;
    }

    public String getColourJpName() {
        return ColourJpName;
    }

    public String getDescription() {
        return Description;
    }

    public void setColourId(Long ColourId) {
        this.ColourId = ColourId;
    }

    public void setCatalogueId(Long CatalogueId) {
        this.CatalogueId = CatalogueId;
    }

    public void setCatalogueName(String CatalogueName) {
        this.CatalogueName = CatalogueName;
    }

    public void setColourCode(String ColourCode) {
        this.ColourCode = ColourCode;
    }

    public void setColourNumber(String ColourNumber) {
        this.ColourNumber = ColourNumber;
    }

    public void setColourCnName(String ColourCnName) {
        this.ColourCnName = ColourCnName;
    }

    public void setColourEnName(String ColourEnName) {
        this.ColourEnName = ColourEnName;
    }

    public void setColourJpName(String ColourJpName) {
        this.ColourJpName = ColourJpName;
    }

    public void setDescription(String Description) {
        this.Description = Description;
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (!(o instanceof ColourEntity)) {
            return false;
        }

        final ColourEntity that = (ColourEntity) o;

        return new EqualsBuilder()
            .append(this.getColourId(), that.getColourId())
            .isEquals();
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public int hashCode() {
        int result = 17;
        result = 31 * result + getColourId().hashCode();

        return result;
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public String toString() {
        //ToStringBuilder sb = new ToStringBuilder(this, ToStringStyle.DEFAULT_STYLE)
        //    .append("ColourCnName", this.ColourCnName);

        //return sb.toString();
        return ToStringBuilder.reflectionToString(this);
    }
}
